<?php
/**
 * <https://y.st./>
 * Copyright © 2015 Alex Yst <mailto:copyright@y.st>
 * 
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 * 
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
 * GNU General Public License for more details.
 * 
 * You should have received a copy of the GNU General Public License
 * along with this program. If not, see <https://www.gnu.org./licenses/>.
**/

$xhtml = array(
	'title' => 'Reworking the website&apos;s compile script',
	'body' => <<<END
<p>
	Thanks to Git, I found that every time I sign a file, even if the file is identical to a file I have already signed, the signature is different.
	It seems that $a[GnuPG] is including information about the time the file was signed within the signature itself.
	Every time that I&apos;ve needed to modify a page, I&apos;ve passed an argument to my compile script that has erased the whole website and built it all from scratch again, generating new signature files.
	Additionally, certain index files relating to the weblog are regenerated every time, regardless of whether the the index is actually in need of updating or not.
	The signatures across almost my entire website therefor include the incorrect signing date.
	So now, on top of everything else I need to do, I need to figure out how to prevent the rebuilding of files that do not need rebuilding.
	I tried this before and got nowhere, but it seems I will need to try harder.
	I feel like this website is having to become ever-more complex.
	It&apos;s only supposed to be a simple website that acts as my home on the Web.
</p>
<p>
	I&apos;ve cobbled together a solution that might work, but I I will need to keep an eye on it over the next while.
	It involves compiling the entire website every time and only writing to disk as needed, as <a href="https://wowana.me/">wowaname</a> had tried to get me to do before.
	The main compile scripts now ignore the creation of signature files and the existence of current files, instead delegating this task to a new function specially designed for the job.
	The function checks to see if it has been handed a $a[GnuPG] handle, if the file already matches what is supposed to be written in it, if the signature file exists, and if the signature file is still valid.
	The lack of ability to delete the whole website has resulted in an inability to clear out deleted pages, so a hacky workaround has been put in place.
	Every time that one of the main compile scripts calls the new function, it also adds one or two keys to an array.
	One key represents the path of the file to be updated and the other represents the file&apos;s signature&apos;s path, if there is a signature.
	At the end of compilation, the script walks the directory tree and checks each non-directory file for an entry in the array.
	If the file is not present in the array, it is erased.
	I fear that this solution will not work long-term.
	The array will grow by at least two keys each day.
	The number of pages to process will grow by at least one each day.
	Recompiling everything and checking each file to see if we should keep it will take longer each day.
	What happens in several years when the website has grown into a monster?
</p>
<p>
	Today I applied for work at that restaurant I visited two days ago.
	The job market sucks and I&apos;m almost certain to end up in another stupid job, if I can find employment at all.
</p>
<p>
	I found an issue with how I was trying to make links to the onion half of this website invisible.
	The $a[CSS] made the <code>&lt;a/&gt;</code> tag itself invisible, but I have a separator character between navigation links.
	As a result, if you looked before, you might have noticed two separator characters in a row.
	I&apos;ve removed the check on the <code>&lt;a/&gt;</code> tags and have switched to using manually-designated <code>&lt;span/&gt;</code> tags.
	It is less automated, but it looks better when rendered.
	Making this change set off the rewriting of all the pages of course, causing the signatures to be recomputed once again.
	At least this time it was for an actual change to these documents though.
</p>
<p>
	Having progressed as far as I&apos;m really going to on this website for the time being, I decided to start work on some sort of Web software project.
	I need to get back into coding.
	However, I could not come up with any project that would actually do the world some good while also being at my skill level.
	So instead, I settled for returning to work on Minetyst.
	However, my thoughts on the project have greatly changed.
	Instead of keeping it hidden until it is usable, I&apos;ve decided to upload the code as it is and just label it as incomplete.
	If other people have ideas and actually stumble upon the project, they are welcome to join me.
	I&apos;ve also separated Minetyst from my name.
	It is now called <a href="https://notabug.org/Thorn/Anarchy_game">Anarchy Game</a>.
</p>
<p>
	My mother just cannot wrap her head around the fact that my mobile doesn&apos;t do text messaging and that if she wants to reach me while I&apos;m out, she&apos;ll have to use email.
	She just text messaged four different numbers trying to reach me.
	I have no clue who she messaged, but is sounds like nobody responded.
</p>
<p>
	My <a href="/a/canary.txt">canary</a> still sings the tune of freedom and transparency.
</p>
END
);
